<template>
	<view>
		<view class="blank"></view>
		<view class="fankuiBox">
			<view class="mainBox" v-for="item in list">
				<view class="flexItemMain">
					<view class="flexItemCenter">
						{{item.created_at}}
					</view>
					<view v-if="item.status ==0" class="flexItemRightImg">未处理</view>
					<view v-else class="flexItemRightImg">已处理</view>
				</view>
				<view class="name">{{item.content}}</view>
				<image class="photoImg" :src="item.image[0]"></image>
			</view>
		</view>
		<view class="nomore">
			<view class="nomoreleft"></view>
			<view class="nomoreMiddle">没有更多了</view>
			<view class="nomoreright"></view>
		</view>
	</view>
</template>

<script>
	export default{
		data() {
			return{
				list: {}
			}
		},
		onShow() {
			this.getData()
		},
		methods:{
			getData() {
				let that = this
				//status为0 未处理   不为0，已处理
				this.$utils.postrequest("/api/help_feedback/userfeedback/list",{page: 1}, function(res) {
					if (res.code == 200) {
						if (res.data.length > 0) {
							res.data.forEach((item) => {
								item.image = JSON.parse(item.image)
							})
						}
						that.list = res.data
			
					}
				})
			}
		}
	}
</script>

<style>
	page{
		background: #F6F7F9;
	}
	.fankuiBox{
		margin-top: 17rpx;
		width: 100%;
		background-color: #fff;
	}
	.blank{
		width: 100%;
		height: 1rpx;
		background: #DDDDDF;
	}
	.mainBox{
		padding: 37rpx 32rpx ;
	}
	.flexItemMain {
		display: flex;
		flex-direction: row;
		align-items: center;
		padding: 30rpx 0;
	}
	
	.flexItemLeft {
		flex: none;
		border-radius: 100%;
		overflow: hidden;
		width: 60rpx;
		height: 60rpx;
		/* margin-left: 30rpx; */
		margin-right: 27rpx;
	}
	
	.flexItemCenter {
		flex: auto;
		text-align: left;
		font-size: 27rpx;
		font-family: PingFang SC;
		
		color: #D1CFDD;
	}
	
	.flexItemRightImg {
		flex: none;
		/* margin-right: 30rpx; */
		margin-left: 10rpx;
		color: #DD0415;
		font-size: 28rpx;
		font-family: PingFang SC;
		
	}
	.name{
		padding-top: 25rpx;
		font-size: 30rpx;
		font-family: PingFang SC;
		
		color: #1A1A1A;
	}
	.photoImg{
		width: 226rpx;
		height: 226rpx;
		border-radius: 13rpx;
		margin-top: 30rpx;
	}
	.nomore {
		display: flex;
		justify-content: center;
		align-items: center;
		margin-top: 60rpx;
	}
	
	.nomoreMiddle {
		font-size: 22rpx;
		font-family: PingFang SC;
		
		color: #C7C8DB;
	
	}
	
	.nomoreleft {
		width: 37rpx;
		height: 1rpx;
		background: #DCDDF3;
		margin-right: 18rpx;
	}
	
	.nomoreright {
		width: 37rpx;
		height: 1rpx;
		background: #DCDDF3;
		margin-left: 18rpx;
	}
</style>
